<!DOCTYPE html>
<html>
	<head>
		<script src = 'tabManager.js' type = 'text/javascript' />
		<script type = 'text/javascript'>
			/*		Chrome Marking Menu
			 *  	by Brenton Simpson
			 *  	bsimpson@appsforartists.com
			 *		1/30/2010
			 */

			/* Intra-page actions are handled by contentActions.js in chrome.tabs, so we send 
			 * action messages back to the tab they came from to be handled.
			 */
			chrome.extension.onRequest.addListener(
				function(message, sender, sendResponse) {
					if (message.action && sender.tab) {
						switch (message.action) {
							case 'getFromLocalStorage':
								console.log(message.variableName + ': ' + localStorage[message.variableName]);
								sendResponse(localStorage[message.variableName]);
								break;
								
							default:
								chrome.tabs.sendRequest(sender.tab.id, message);
								break;
						}
					}
				}
			);
		</script>
	</head>
</html>